<?php
	require_once( 'core_DataBaseConnect.php' );
	require_once( 'core_ErrorCode.php' );
	require_once( 'core_Response.php' );
	require_once( 'core_FileManager.php' );
	require_once( 'dao_MemberDAO.php' );
	require_once( 'dao_ServiceConfigure.php' );
	require_once( '_configs.php' );
	
	function func( $con, $post, $returnType )
	{
		$login_member_id 	= $post[ 'login_member_id' ];
		// 0. 작성 권한 설정 ( 최고 관리자 or 운영자 )
		if( MemberDAO::isAccessable( $con, $login_member_id, array( configs::AUTHOR_ADMIN, configs::AUTHOR_MANAGER ) ) == false )
		{
			// 작성권한 없음
			return Response::FAIL( ErrorCode::FAIL_WRITE_AUTHOR, "작성권한이 없습니다.", $returnType );
		}
		
		ServiceConfigure::updateServerNotice( 	$con, 
												$post[ 'seq' ],
												$post[ 'serverLock' ], 
												$post[ 'start' ], 
												$post[ 'end' ], 
												$post[ 'message' ],
												$post[ 'enable' ],
												$login_member_id );
		
		
		// 7. 응답값 전송
		return Response::SUCCESS( null, $returnType );
	}
?>